package renguanyu.app.auth4fx.util;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.UUID;

public class Util {

    public static String uuid(){
        return UUID.randomUUID().toString().replace("-","");
    }

    public static void threadSleep(int second){
        try {
            Thread.sleep(second*1000);
        } catch (InterruptedException e) {
            throw new RuntimeException(e);
        }
    }

    public static String getLoginName(){
        return "guanyu.ren";
    }

    private static DateTimeFormatter FORMATTER = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
    public static String getCurrentDateTimeString() {
        return LocalDateTime.now().format(FORMATTER);
    }


}
